<template>
  <div>
    莫愁前路无知己，天下谁人不识君。
    <button type="button" @click="add()">添加</button>
  </div>
</template>

<script>
// import store from '@/store'
import store from '../store/index'

export default {
  name: 'Info',
  store,
  // mounted:生命周期
  mounted () {
    window.vue = this
  },
  methods: {
    add () {
      console.log('add Event from info')
      // alert()
      // debugger
      store.commit('increase')
    },
    output () {
      console.log('in output')
    }
  }
}
</script>

<style scoped>

</style>
